package svc

import (
	"backend/internal/config"
	"backend/model"

	"github.com/zeromicro/go-zero/core/stores/sqlx"
)

type ServiceContext struct {
	Config         config.Config
	FundModel      model.FundModel
	FundScoreModel model.FundScoreModel
	// Add more dependencies here, such as:
	// FundModel model.FundModel
}

func NewServiceContext(c config.Config) *ServiceContext {
	conn := sqlx.NewMysql(c.Database.DataSource)
	return &ServiceContext{
		Config:         c,
		FundModel:      model.NewFundModel(conn),
		FundScoreModel: model.NewFundScoreModel(conn),
		// Initialize other dependencies here
	}
}
